#include <stdio.h>
#define N 6
int main(void)
{
    int s[N] = {0}, i, j, min;
    for (i = 0; i < N; i++)
        scanf("%d", &s[i]);
    for (i = 0; i < N; i++)
    {
        for (j = i + 1; j < N; j++)
        {
            if (s[j] < s[i])
            {
                s[i] = s[j] * s[i];
                s[j] = s[i] / s[j];
                s[i] = s[i] / s[j];
            }
        }
        printf("%d ", s[i]);
    }
}